package com.project.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.project.entity.po.Employee;import org.apache.ibatis.annotations.Param;import java.util.List;

/**
 * @ProjectName:
 * @Package:
 * @ClassName:
 * @Author: qianhui
 * @CreateDate:
 */
public interface EmployeeMapper extends BaseMapper<Employee> {
    /**
     * 查询所有员工信息
     *
     * @return
     */
    List<Employee> selectAllEmployee();

    /**
     * 根据ID删除员工信息(伪删除)
     *
     * @param
     * @return
     */
    int updateEmployeeById(@Param("employeeId") Long id);

    /**
     * 根据员工名字和状态值进行模糊查询
     *
     * @return
     */
    List<Employee> selectEmployeeByName(@Param("employeeName") String name, @Param("status") int status);

    /**
     * 根据ID查询员工信息
     *
     * @param id
     * @return
     */
    Employee selectEmployeeById(@Param("employeeId") Long id);

    /**
     * 添加员工
     *
     * @param
     * @return
     */
    int insertEmployee(Employee employee);

    /**
     * 修改员工信息
     *
     * @param employee
     * @return
     */
    int updateEmployee(Employee employee);

    /**
     * 根据id修改值班信息
     *
     * @return
     */
    int updateEmployeeByDutyId(@Param("dutyId") Long dutyId, @Param("employeeId") Long id);
}